<template>
  <div>
    <km-search :KmType="kmType" @updateTreeData="updateTreeData"></km-search>
    <km-detail :treeChilds="treeData"></km-detail>
  </div>
</template>
<script>
  import kmSearch from '@/components/business-modules/km/km-search/index.vue'
  import kmDetail from '@/components/business-modules/km/km-detail/index.vue'
  export default {
    name: 'KM1',
    data () {
      return {
        treeData: []
      }
    },
    props: {
      kmType: {type: String, default: 'inner'}
    },
    methods: {
      updateTreeData(val) {
        this.treeData = val
      }
    },
    components: {
      kmSearch,
      kmDetail
    },
    beforeMount () {
    }
  }
</script>
<style lang="stylus" scoped>
</style>
